/**
 * FileName: EmployeeService.java
 * 员工业务层
 *
 * @author  王威
 * @Date    2021/12/1
 * @version 1.00
 **/
package com.site.service;

import com.site.pojo.Employee;
import com.site.pojo.EmployeeRole;
import com.site.vo.UserControlVO;

import java.sql.Connection;
import java.sql.SQLException;
import java.util.List;

public interface EmployeeService {
    /*按照姓名查询员工*/
    Employee selectByname(Employee employee) throws SQLException;

    /*按照id查询员工*/
    Employee selectById(Employee employee) throws SQLException;

    /*查询所有员工*/
    List<Employee> selectAll() throws SQLException;

    /*添加员工*/
    boolean addEmployee(Employee employee,EmployeeRole employeeRole) throws SQLException;

    /*添加事务员工*/
    boolean addEmployee(Connection con, Employee employee) throws SQLException;

    /*删除员工*/
    boolean delEmplyee(Connection con, Employee employee);

    /*删除员工事务*/
    boolean delEmplyee(Employee employee,EmployeeRole employeeRole) throws SQLException;

    /*修改员工*/
    boolean updateEmlyee(Connection con,Employee employee);

    /*修改员工事务*/
    boolean updateEmlyee(Employee employee,EmployeeRole employeeRole);

    /*账户登录*/
    Employee login(Employee employee) throws SQLException;

    /*用户管理视图*/
    List<UserControlVO> selectUserVO() throws SQLException;
}
